package com.jhopesoft.framework.dao.entity.common;
// Generated 2021-04-06 14:21:22 by Quick build System

import java.io.Serializable;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.jhopesoft.framework.dao.entity.dataobject.FNotification;
import com.jhopesoft.framework.dao.entity.system.FUser;

import org.hibernate.annotations.DynamicUpdate;
import org.hibernate.annotations.GenericGenerator;

/**
*
* FUsernotification(FUsernotification) generated by Quick Build System 
*
* 了解快速架构系统 https://github.com/jfok1972
*
* @author 蒋锋 jfok1972@qq.com
*
*/
@Entity
@DynamicUpdate
@SuppressWarnings("serial")
@Table(name = "f_usernotification")
public class FUsernotification implements Serializable {

	/** 用户通知公告id */
	private String usernotificationid;
	/** 用户ID */
	private FUser FUser;
	/** 通知公告id */
	private FNotification FNotification;

	public FUsernotification() {
	}

	@Id
	/** 请使用 strategy = "uuid.hex" 主键中最好不要有“-”号 */
	@GeneratedValue(generator = "generator")
	@GenericGenerator(name = "generator", strategy = "uuid.hex")
	@Column(name = "usernotificationid", unique = true, nullable = false, length = 40)
	public String getUsernotificationid() {
		return this.usernotificationid;
	}

	public void setUsernotificationid(String usernotificationid) {
		this.usernotificationid = usernotificationid;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "userid", nullable = false)
	public FUser getFUser() {
		return this.FUser;
	}

	public void setFUser(FUser FUser) {
		this.FUser = FUser;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "notificationid", nullable = false)
	public FNotification getFNotification() {
		return this.FNotification;
	}

	public void setFNotification(FNotification FNotification) {
		this.FNotification = FNotification;
	}

}
